home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / Apps / DevTools / eText5 / Source / unused4Code / BBC.bproj / BBC.h < prev    next >
Encoding:
C/C++ Source or Header  |  1994-05-31  |  1.8 KB  |  70 lines

  1. ///////////////////////////////////////////////////////////////////////////////
  2. //    FILENAME:    BBC.h 
  3. //    SUMMARY:    Interface for a Billiard-Ball Computation Annotation
  4. //    SUPERCLASS:    Object
  5. //    INTERFACE:    None
  6. //    PROTOCOLS:    <DocNotification,Annotation,Tool,ASCIISupport>
  7. //    AUTHOR:        Rohit Khare
  8. //    COPYRIGHT:    (c) 1994 California Institure of Technology, eText Project
  9. //    COPYRIGHT:    (c) 1992 Rohit Khare (core simulation code)
  10. ///////////////////////////////////////////////////////////////////////////////
  11. //    DESCRIPTION
  12. //        A quintessential example of an eText Annotation. A BBC-simulator
  13. //  brings the entire discussion "alive". It also demonstrates the programming
  14. //  technique for reusing already-written View classes.
  15. //        Separated out model from old BilliardView code.
  16. ///////////////////////////////////////////////////////////////////////////////
  17. //    HISTORY
  18. //    05/29/94:    Created as an eText Annotation.
  19. //    1992-93:    Developed for CS20ab.
  20. ///////////////////////////////////////////////////////////////////////////////
  21.  
  22. #import "eTextKernel.h"
  23. #import "BBCUI.h"
  24.  
  25. @interface BBC : Object <DocNotification,Annotation,Tool,ASCIISupport>
  26. {
  27.     NXAtom theName;
  28.     char **state;
  29.     char **oldstate;
  30.     BOOL isAccelerated;
  31.     BOOL isEditable;
  32.     BOOL doesShowPath;
  33.     BOOL dirFwd;
  34.     BOOL isLinked;
  35.     int hres, vres;
  36.     id    bbcView;
  37.     id    scrollView;
  38.     id    etDoc;
  39. }
  40.  
  41. - (NXAtom) name;
  42. - (char *) filename;
  43. - (BOOL) doesShowPath;
  44. - (BOOL) isAccelerated;
  45. - (BOOL) isEditable;
  46. - (int) hres;
  47. - (int) vres;
  48. - (char **) state;
  49. - setName:(NXAtom) newName;
  50. - setShowPath:(BOOL) newState;
  51. - setAccelerated:(BOOL) newState;
  52. - setEditable:(BOOL) newState;
  53. - setRes:(int)h :(int)v;
  54. - stepForward;
  55. - reverse;
  56. - stepBackward;
  57. - step;
  58. @end
  59.  
  60. @interface BilliardView : View
  61. {
  62.     id        theBBC;
  63.     int     x,y;
  64.     id         Mucus, Wall, N,S,E,W, Empty, Grid;
  65.     id        cacheGrid;
  66. }
  67. - setBBC:newBBC;
  68. - setRes:(int) hres :(int) vres;
  69. @end
  70.